package com.yudean.esb.service;

import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebService;

/**
 * Created by zenghui on 2015-05-27.
 * desc:天鑫理赔系统与ERP数据交换
 */
@WebService
public interface ERPInsuranceService {
    /**
     * @param compCodeStr   公司代码
     * @param startDateStr  生效日
     * @param endDateStr    到期日
     * @param insTypeStr    险种
     * @param insNumberStr  保单号
     * @return              根据公司代码，生效日，到期日，险种，保单号获取公司的保单数据
     */
    @WebMethod(action = "getInsuranceData")
    String getInsuranceData(@WebParam(name = "compCodeStr")String compCodeStr,
                            @WebParam(name = "startDateStr")String startDateStr,
                            @WebParam(name = "endDateStr")String endDateStr,
                            @WebParam(name = "insTypeStr")String insTypeStr,
                            @WebParam(name = "insNumberStr")String insNumberStr
    );


    /**
     *
     * @param dangerIntXML 数据
     * 格式：
     *  <?xml version="1.0" encoding="UTF-8"?>
     *   <service>
     *       <name>出险赔付信息</name>
     *       <type>写入数据</type>
     *       <data>
     *          <ErpIdsInsDangerInt>
     *               <compCode>H</compCode>
     *               <insNumber>dd</insNumber>
     *               <endorSementNum>ddasd</endorSementNum>
     *               <dangerDate>2015-05-20 00:33:09.716 UTC</dangerDate>
     *               <insSubject>dasd</insSubject>
     *               <estimateAmount>22</estimateAmount>
     *               <insReason>dasd</insReason>
     *               <closeType>dasdf</closeType>
     *               <closeResult>dasf</closeResult>
     *               <processStatus>dfasd</processStatus>
     *               <creationDate>2015-05-20 00:33:09.717 UTC</creationDate>
     *               <createdBy>22</createdBy>
     *               <lastUpdateDate>2015-05-20 00:33:09.717 UTC</lastUpdateDate>
     *               <lastUpdatedBy>22</lastUpdatedBy>
     *               <attribute1>33</attribute1>
     *               <attribute2>33</attribute2>
     *               <attribute3>33</attribute3>
     *               <attribute4>33</attribute4>
     *               <attribute5>33</attribute5>
     *               <attribute6>33</attribute6>
     *               <attribute7>33</attribute7>
     *               <attribute8>33</attribute8>
     *               <attribute9>33</attribute9>
     *               <attribute10>33</attribute10>
     *          </ErpIdsInsDangerInt>
     *           ...
     *       </data>
     *   </service>
     * @return 写入出险赔付信息
     */
    @WebMethod(action = "putDangerInt")
    String putDangerInt(String dangerIntXML);

    /**
     *
     * @param dangerTypeXML 数据
     * 格式：
     *  <?xml version="1.0" encoding="UTF-8"?>
     *   <service>
     *       <name>险种信息</name>
     *       <type>写入数据</type>
     *       <data>
     *           <ErpIdsInsDangerType>
     *               <insTypeCode>InsTypeCode</insTypeCode>
     *               <insTypeName>insName</insTypeName>
     *               <creationDate>2015-05-19 07:36:28.620 UTC</creationDate>
     *               <createdBy>11</createdBy>
     *               <lastUpdateDate>2015-05-19 07:36:28.620 UTC</lastUpdateDate>
     *               <lastUpdatedBy>11</lastUpdatedBy>
     *               <attribute1>attribute1</attribute1>
     *               <attribute2>attribute2</attribute2>
     *               <attribute3>attribute3</attribute3>
     *               <attribute4>attribute4</attribute4>
     *               <attribute5>attribute5</attribute5>
     *           </ErpIdsInsDangerType>
     *           <ErpIdsInsDangerType>
     *               ...
     *               <createdBy>11</createdBy>
     *               <lastUpdateDate>2015-05-19 07:36:28.620 UTC</lastUpdateDate>
     *               <lastUpdatedBy>11</lastUpdatedBy>
     *               <attribute1>attribute1</attribute1>
     *               ...
     *           </ErpIdsInsDangerType>
     *           ...
     *       </data>
     *   </service>
     *
     * @return  写入险种信息
     */
    @WebMethod(action = "putDangerType")
    String putDangerType(String dangerTypeXML);


    /**
     * @param insTypeCode   险种编码
     * @return              删除险种信息
     */
    @WebMethod(action = "deleteDangerType")
    String deleteDangerType(String insTypeCode);
}
